package com.youku.core.view.components
{
   import flash.display.Sprite;
   import com.youku.core.view.interfaces.IVideo;
   import com.youku.interfaces.IPlayerProxy;
   import com.youku.interfaces.IPlayListData;
   import flash.utils.Timer;
   import com.youku.utils.DropFrameTable;
   import com.youku.PlayerConfig;
   import com.youku.events.ReportEvent;
   import com.youku.events.PlayerControlEvent;
   import com.youku.P2PConfig;
   import com.youku.utils.Log;
   import com.youku.core.view.events.BaseVideoEvent;
   import com.youku.events.CoreEvent;
   import flash.utils.getTimer;
   import com.youku.data.LoadTimeData;
   import flash.utils.setTimeout;
   import flash.events.TimerEvent;
   import com.youku.interfaces.IVideoSegmentData;
   import com.youku.interfaces.IVideoSegmentStatus;
   import flash.media.Video;
   import flash.net.NetStream;
   
   public class BaseCore extends Sprite
   {
      
      public function BaseCore(param1:IPlayerProxy, param2:CoreBase) {
         this._videoArr = [];
         super();
         this._playerProxy = param1;
         this._corebase = param2;
         this._startTime = 0;
         this._currentVideoNum = 0;
         this._loadedTime = 0;
         this._nsTime = 0;
         this._currentLoadingNum = 0;
         this._storeVolume = 0;
         this._isPause = true;
         this._bufferFlag = 0;
         this._bufferOneTimeCount = 0;
         this._bufferedCount = 0;
         this._lastCountedTime = 0;
         this._lastSentVideoReportTime = 0;
         this._lastSentVVLogTime = 0;
         this._lastRecordWatchingTime = 0;
         this._actualPlayTime = 0;
         this._sendStaticReport = true;
         this._sendWplaylog = true;
         this._firstGetMetadata = true;
         this._firstConnectVideo = true;
         this._firstLoadFull = true;
         this._ltvideoview = 0;
         this._stvideoview = 0;
         this._timer = new Timer(50);
         this._timer.addEventListener(TimerEvent.TIMER,this.onTimer);
      }
      
      public static var VideoUrlArr:Array = [];
      
      public static var VideoSecondArr:Array = [];
      
      public static var VideoSizeArr:Array = [];
      
      protected var _width:Number;
      
      protected var _height:Number;
      
      protected var _mode:String;
      
      protected var _isRenderSize:Boolean = true;
      
      protected var _currentPlayVideo:IVideo;
      
      protected var _currentVideoNum:int;
      
      protected var _currentLoadingNum:Number;
      
      protected var _preVideoNum:int;
      
      protected var _loadedTime:Number;
      
      protected var _nsTime:Number;
      
      protected var _dragHold:Boolean;
      
      protected var _playOver:Boolean;
      
      protected var _playStarted:Boolean;
      
      protected var _isPause:Boolean = true;
      
      protected var _startTime:Number = 0;
      
      protected var _firstGetMetadata:Boolean = true;
      
      protected var _firstConnectVideo:Boolean = true;
      
      protected var _firstLoadFull:Boolean = true;
      
      protected var _sendStaticReport:Boolean = true;
      
      protected var _sendWplaylog:Boolean = true;
      
      protected var _playerProxy:IPlayerProxy;
      
      protected var _playListData:IPlayListData;
      
      protected var _corebase:CoreBase;
      
      protected var _isWaitingLoad:Boolean = false;
      
      protected var _delayResume:Boolean = false;
      
      protected var _storeVolume:Number;
      
      protected var _bufferFlag:int = 0;
      
      protected var _bufferOneTimeCount:int = 0;
      
      protected var _bufferedCount:int = 0;
      
      protected var _bufferTime:int = 0;
      
      protected var _bufferTimeFlag:int = 0;
      
      protected var _lastCountedTime:Number;
      
      protected var _lastSentVideoReportTime:Number;
      
      protected var _lastSentVVLogTime:Number;
      
      protected var _lastRecordWatchingTime:Number;
      
      protected var _actualPlayTime:Number;
      
      protected var _timer:Timer;
      
      protected var _dfTable:DropFrameTable;
      
      protected var _videoArr:Array;
      
      protected var _vd:VideoDisplay;
      
      private var _ltvideoview:Number = 0;
      
      private var _stvideoview:Number = 0;
      
      public function init(param1:Number, param2:Number) : void {
         this._playListData = PlayerConfig.playListData;
         this._isRenderSize = true;
         this._width = param1;
         this._height = param2;
         this._vd = new VideoDisplay(this._playerProxy,this);
         this._vd.init(param1,param2);
         addChild(this._vd);
         this._playerProxy.dispatchEvent(new ReportEvent(ReportEvent.CORE_INIT_EVENT,{}));
      }
      
      protected function updateVideo() : void {
         if(this.currentNetstream == null)
         {
            return;
         }
         var _loc1_:Boolean = this._vd.updateVideo(this.currentNetstream);
         this.stageVideoInUse(_loc1_);
      }
      
      private function stageVideoInUse(param1:Boolean) : void {
         PlayerConfig.isStageVideoInUse = param1;
         if(param1)
         {
            this._corebase.removeOverlays();
            this._playerProxy.dispatchEvent(new PlayerControlEvent(PlayerControlEvent.HIDE_BACKGROUND));
         }
         else
         {
            this._corebase.addOverlays();
            this._playerProxy.dispatchEvent(new PlayerControlEvent(PlayerControlEvent.SHOW_BACKGROUND));
         }
      }
      
      protected function setVideoUrlArr() : void {
         var _loc3_:IVideo = null;
         var _loc4_:String = null;
         if(!P2PConfig.isSSPlayer)
         {
            return;
         }
         VideoUrlArr = [];
         VideoSecondArr = [];
         VideoSizeArr = [];
         var _loc1_:Number = 0;
         if(!(this._playListData.fileType == null) && !(this._playListData.fileType == ""))
         {
            _loc1_ = this._playListData.videoSegmentsDic[this._playListData.fileType].length;
         }
         Log.log("Trace","setVideoUrlArr len =" + this._videoArr.length + " curlen = " + _loc1_);
         var _loc2_:* = 0;
         while(_loc2_ < _loc1_)
         {
            _loc3_ = this._videoArr[_loc2_] as IVideo;
            _loc4_ = _loc3_.getFileURL(false);
            VideoUrlArr.push(_loc4_);
            VideoSecondArr.push(_loc3_.segmentData.seconds);
            VideoSizeArr.push(_loc3_.segmentData.size);
            _loc2_++;
         }
      }
      
      public function reInit() : void {
         this._isRenderSize = true;
         this._currentPlayVideo = null;
         this._currentVideoNum = 0;
         this._currentLoadingNum = 0;
         this._preVideoNum = 0;
         this._loadedTime = 0;
         this._nsTime = 0;
         this._dragHold = false;
         this._playOver = false;
         this._playStarted = false;
         this._isPause = true;
         this._startTime = 0;
         this._firstGetMetadata = true;
         this._firstConnectVideo = true;
         this._firstLoadFull = true;
         this._sendWplaylog = true;
         this._sendStaticReport = true;
         if(PlayerConfig.dvdPlay)
         {
            this._sendStaticReport = false;
         }
         this._isWaitingLoad = false;
         this._delayResume = false;
         this._lastCountedTime = 0;
         this._lastSentVideoReportTime = 0;
         this._lastSentVVLogTime = 0;
         this._lastRecordWatchingTime = 0;
         this._actualPlayTime = 0;
         this._ltvideoview = 0;
         this._stvideoview = 0;
         this._bufferFlag = 0;
         this._bufferOneTimeCount = 0;
         this._bufferedCount = 0;
         this._bufferTime = 0;
         this._bufferTimeFlag = 0;
      }
      
      public function startToPlay() : void {
         this._timer.reset();
         this._timer.start();
      }
      
      protected function getVideoByNum(param1:Number) : IVideo {
         return null;
      }
      
      protected function onVideoPlayStart(param1:BaseVideoEvent) : void {
         var _loc2_:String = null;
         var _loc3_:* = 0;
         var _loc4_:* = NaN;
         Log.log("Stop","BaseCore.onVideoPlayStart _playStarted = " + this._playStarted + " _isWaitingLoad = " + this._isWaitingLoad + "_startTime=" + this._startTime);
         if(!this._playStarted)
         {
            this._playStarted = true;
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.PLAY_START));
         }
         if(param1.data.dt != null)
         {
            _loc2_ = this.playListData.sid.substr(-2);
            _loc3_ = int(_loc2_);
            if(_loc3_ % 100 == 0)
            {
               _loc4_ = param1.data.dt;
               this._playerProxy.dispatchEvent(new ReportEvent(ReportEvent.DELAY_TIME_REPORT,{"dt":_loc4_}));
            }
         }
      }
      
      private function recordLoadTime(param1:Boolean) : void {
         var _loc2_:Number = getTimer();
         this._ltvideoview = _loc2_ - this._stvideoview;
         PlayerConfig.loadtimeData.ltvideoview_end = new Date().getTime();
         PlayerConfig.loadtimeData.ltvideoview = this._ltvideoview;
         var _loc3_:Object = {};
         _loc3_.type = param1?"error":"report";
         _loc3_.stage = LoadTimeData.LOAD_STAGE_VIDEO_VIEW;
         this._playerProxy.dispatchEvent(new ReportEvent(ReportEvent.PLAYER_LOAD_TIME_EVENT,_loc3_));
         this._playerProxy.dispatchEvent(new ReportEvent(ReportEvent.LOAD_TIME_REPORT,
            {
               "isError":param1,
               "type":LoadTimeData.TYPE_VIDEO,
               "errorCode":(param1?LoadTimeData.ERROR_CODE_STREAM:null)
            }));
      }
      
      protected function onVideoPlayOver(param1:BaseVideoEvent) : void {
      }
      
      protected function onVideoJumpPlay(param1:BaseVideoEvent) : void {
      }
      
      protected function onVideoInvalidPlayEvent(param1:BaseVideoEvent) : void {
      }
      
      protected function onDRMError(param1:BaseVideoEvent) : void {
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.VIDEO_DRM_NOT_SUPPORT));
      }
      
      protected function onVideoConnectStart(param1:BaseVideoEvent) : void {
         if(this._firstConnectVideo)
         {
            this._firstConnectVideo = false;
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.CONNECT_START));
         }
      }
      
      protected function onVideoConnectDone(param1:BaseVideoEvent) : void {
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.CONNECT_DONE));
      }
      
      protected function onVideoLoadBufferFull(param1:BaseVideoEvent) : void {
         if(this._firstLoadFull)
         {
            this._firstLoadFull = false;
            this.recordLoadTime(false);
         }
         if(this._isWaitingLoad)
         {
            this.pauseToWaitLoad(this._startTime);
         }
      }
      
      protected function onVideoGotMetadata(param1:BaseVideoEvent) : void {
         var _loc2_:IVideo = null;
         if(param1.data.num == this.currentPlayVideo.num)
         {
            this.setScreenMode(this._mode,false);
         }
         if(this._firstGetMetadata)
         {
            this._firstGetMetadata = false;
            _loc2_ = this.getVideoByNum(param1.data.num);
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.GOT_METADATA,{"video":_loc2_}));
         }
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_DYNAMIC_REPORT,
            {
               "code":"3001",
               "number":param1.data.num
            }));
      }
      
      protected function onVideoLoadError(param1:BaseVideoEvent) : void {
         var _loc2_:Number = param1.data.num == null?0:param1.data.num;
         if(!this._playStarted)
         {
            this.recordLoadTime(true);
         }
         if(this.currentVideoNum == _loc2_)
         {
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.VIDEO_NOT_FOUND));
         }
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_DYNAMIC_REPORT,
            {
               "code":"2001",
               "number":_loc2_
            }));
      }
      
      protected function onRTMPVideoFailError(param1:BaseVideoEvent) : void {
         var _loc2_:Number = param1.data.num == null?0:param1.data.num;
         if(this.currentVideoNum == _loc2_)
         {
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.VIDEO_RTMP_FAIL));
         }
      }
      
      protected function onVideoEarlyRequestError(param1:BaseVideoEvent) : void {
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.VIDEO_EARLY_REQUEST));
      }
      
      protected function onVideoMiddleError(param1:BaseVideoEvent) : void {
         var playingVideo:IVideo = null;
         var time:Number = NaN;
         var e:BaseVideoEvent = param1;
         var num:Number = e.data.num == null?0:e.data.num;
         playingVideo = this.getVideoByNum(e.data.num);
         time = playingVideo.nsTime;
         var delaySeek:Function = function():void
         {
            playingVideo.resetNS();
            playingVideo.seek(time);
         };
         setTimeout(delaySeek,500);
      }
      
      protected function onVideoBufferFull(param1:BaseVideoEvent) : void {
         var _loc2_:Number = param1.data.num == null?0:param1.data.num;
         this._bufferFlag = 0;
         this._bufferTimeFlag = 0;
         if(_loc2_ == this.currentVideoNum)
         {
            this._bufferOneTimeCount = 0;
            this._bufferTime = 0;
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_FULL));
         }
         this.updateVideo();
      }
      
      protected function onVideoBufferEmpty(param1:BaseVideoEvent) : void {
         var _loc2_:Number = param1.data.num == null?0:param1.data.num;
         var _loc3_:Boolean = param1.data.isRealBuffer;
         if(_loc2_ == this.currentVideoNum)
         {
            if(_loc3_)
            {
               this._bufferFlag = 1;
            }
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_EMPTY));
         }
      }
      
      protected function onVideoBufferPercent(param1:BaseVideoEvent) : void {
         var _loc3_:* = NaN;
         var _loc2_:Number = param1.data.num == null?0:param1.data.num;
         if(_loc2_ == this.currentVideoNum)
         {
            _loc3_ = param1.data.per;
            if(_loc3_ < 1)
            {
               this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_PERCENT,{"per":_loc3_}));
            }
         }
      }
      
      protected function onVideoP2PError(param1:BaseVideoEvent) : void {
      }
      
      protected function onTimer(param1:TimerEvent) : void {
         if(this._playOver)
         {
            return;
         }
         if(this._sendStaticReport)
         {
            this.sendFirstRecord();
         }
         this.computeBufferRelated();
         this.checkDownloadComplete();
         this.checkContinueDownloading();
         this.checkChangeVideo();
         this.updateTime();
         this.updateBytes();
         this.updateDroppedFrame();
         this.sendTimeRelatedReports();
      }
      
      private function sendFirstRecord() : void {
         this._sendStaticReport = false;
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_STATIC_REPORT));
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_VIDEO_TIME_REPORT,
            {
               "times":59,
               "starttime":this._startTime
            }));
         this._playerProxy.fsoProxy.clearUserWatchingRecord();
         this._lastRecordWatchingTime = getTimer();
      }
      
      private function computeBufferRelated() : void {
         if(this._bufferFlag == 0)
         {
            return;
         }
         this.computeBufferTime();
         this._bufferOneTimeCount++;
         if(this._bufferOneTimeCount <= 20)
         {
            return;
         }
         this._bufferOneTimeCount = 0;
         this._bufferedCount++;
         if(this._bufferedCount == 2)
         {
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_COUNT_LIMITED));
         }
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_APPEARED,{"number":this.currentVideoNum}));
      }
      
      private function computeBufferTime() : void {
         if(this._bufferTimeFlag != 0)
         {
            return;
         }
         this._bufferTime++;
         if(this._bufferTime > 200)
         {
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.BUFFER_TIMEOUT));
            this._bufferTimeFlag = 1;
            this._bufferTime = 0;
         }
      }
      
      protected function checkDownloadComplete() : void {
      }
      
      protected function checkContinueDownloading() : void {
      }
      
      protected function checkChangeVideo() : void {
      }
      
      protected function updateBytes() : void {
      }
      
      protected function updateTime() : void {
      }
      
      protected function updateDroppedFrame() : void {
      }
      
      private function sendTimeRelatedReports() : void {
         var _loc1_:Number = getTimer();
         if((this._isPause) || this._bufferFlag == 1)
         {
            this._lastCountedTime = _loc1_;
         }
         else
         {
            this._actualPlayTime = this._actualPlayTime + (_loc1_ - this._lastCountedTime);
            this._lastCountedTime = _loc1_;
            if(this._actualPlayTime - this._lastSentVVLogTime > 1 * 5 * 1000)
            {
               this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_VIDEO_TIME_REPORT,{"times":5}));
               this._lastSentVVLogTime = this._actualPlayTime;
            }
            if(this._actualPlayTime - this._lastSentVideoReportTime > 1 * 60 * 1000)
            {
               this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_VIDEO_TIME_REPORT,{"times":60}));
               this._lastSentVideoReportTime = this._actualPlayTime;
            }
         }
         if((this.playListData.show) && (this.playListData.show.isVideoPaid == 1) && this.playListData.trial == null)
         {
            if(this._actualPlayTime > 5 * 60 * 1000 && (this._sendWplaylog))
            {
               this._sendWplaylog = false;
               this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_WPLAY_LOG_REPORT));
            }
         }
         if(_loc1_ - this._lastRecordWatchingTime > 10 * 1000)
         {
            this.saveWatchingRecord();
         }
      }
      
      public function seek(param1:Number) : void {
      }
      
      public function mockSeek(param1:Number) : void {
      }
      
      public function seekLoad(param1:Number) : void {
      }
      
      public function play(param1:Number = 0) : void {
         this._playOver = false;
         if(param1 == 0)
         {
            this.currentPlayVideo.play();
         }
         else
         {
            this.seek(param1);
         }
         this._startTime = param1;
         this._isPause = false;
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.RESUME));
      }
      
      public function playWaitLoad(param1:Number = 0) : void {
         this._stvideoview = getTimer();
         PlayerConfig.loadtimeData.ltvideoview_start = new Date().getTime();
         this._playOver = false;
         this._isWaitingLoad = true;
         if(param1 > this._playListData.totalTime)
         {
            param1 = 0;
         }
         this.seekLoad(param1);
         this._startTime = param1;
         if(PlayerConfig.isRTMP)
         {
            this.volume = this.volume;
            return;
         }
      }
      
      protected function pauseToWaitLoad(param1:Number) : void {
         if(this._playOver == true)
         {
            return;
         }
         this.visible = true;
         this._isWaitingLoad = false;
         if(this._delayResume)
         {
            this._delayResume = false;
            this.resume();
         }
      }
      
      protected function closeVideo(param1:IVideo, param2:Boolean = true) : void {
         if(param1 == null)
         {
            return;
         }
         if(this.playListData.controller.area_code == "110000" || this.playListData.controller.area_code.substr(0,4) == "3303" && this.playListData.controller.dma_code == "4134")
         {
            if(!(param1.loadedTime == 0) && param1.nsTime < param1.loadedTime)
            {
               this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_WASTE_REPORT,
                  {
                     "code":"5000",
                     "number":param1.num
                  }));
            }
         }
         param1.close(param2);
      }
      
      public function close() : void {
         this.saveWatchingRecord();
         this._vd.clear();
         this._timer.stop();
         this._playOver = true;
      }
      
      public function get volume() : Number {
         return this._storeVolume;
      }
      
      public function set volume(param1:Number) : void {
      }
      
      public function pause(param1:Boolean = false) : void {
         if(this.currentPlayVideo)
         {
            this.currentPlayVideo.pause();
            this._isPause = true;
            this._corebase.dispatchEvent(new CoreEvent(CoreEvent.PAUSE,{"useraction":param1}));
         }
      }
      
      public function resume() : void {
         if(this._isWaitingLoad)
         {
            this._delayResume = true;
            return;
         }
         this.currentPlayVideo.resume();
         this._isPause = false;
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.RESUME));
      }
      
      public function togglePausePlay(param1:Boolean = false) : void {
         if(this._isPause)
         {
            this._isPause = false;
            this.resume();
         }
         else
         {
            this._isPause = true;
            this.pause(param1);
         }
      }
      
      public function setQuality(param1:String) : void {
         var _loc2_:Number = this._nsTime;
         this._playListData.fileType = param1;
         this._playListData.resetTimeArr();
         this.resetData();
         this.seek(_loc2_);
      }
      
      public function setDragging(param1:Boolean) : void {
         this._dragHold = param1;
      }
      
      public function resetData() : void {
      }
      
      public function jumpTail() : void {
         if(this.currentPlayVideo != null)
         {
            this.currentPlayVideo.pause();
         }
         this._isPause = true;
         this._playOver = true;
         this.saveWatchingRecord(true);
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.SEND_DYNAMIC_REPORT,
            {
               "code":"3008",
               "number":this.currentPlayVideo.num
            }));
         this._corebase.dispatchEvent(new CoreEvent(CoreEvent.PLAY_OVER));
      }
      
      public function get time() : Number {
         return this._nsTime;
      }
      
      public function getTimeStatus(param1:Number, param2:String = "") : Object {
         var _loc9_:IVideoSegmentData = null;
         var _loc3_:Array = [];
         if(param2 == "")
         {
            _loc3_ = this._playListData.segArr;
         }
         else
         {
            _loc3_ = this._playListData.videoSegmentsDic[param2];
         }
         if(_loc3_ == null)
         {
            return null;
         }
         var _loc4_:Number = 0;
         var _loc5_:IVideoSegmentData = null;
         var _loc6_:Number = 0;
         var _loc7_:* = 0;
         while(_loc7_ < _loc3_.length)
         {
            _loc9_ = _loc3_[_loc7_] as IVideoSegmentData;
            _loc4_ = _loc4_ + _loc9_.seconds;
            if(_loc4_ > param1)
            {
               _loc5_ = _loc9_;
               _loc6_ = param1 - (_loc4_ - _loc9_.seconds);
               break;
            }
            _loc7_++;
         }
         if(_loc5_ == null)
         {
            return null;
         }
         var _loc8_:Object = {};
         _loc8_.internalTime = _loc6_;
         _loc8_.seg = _loc5_;
         return _loc8_;
      }
      
      public function getVideoSegmentStatus(param1:Number) : IVideoSegmentStatus {
         return null;
      }
      
      public function setWH(param1:Number, param2:Number) : void {
         this._width = param1;
         this._height = param2;
         this._vd.setWH(param1,param2,this._isRenderSize);
      }
      
      public function setScreenMode(param1:String, param2:Boolean) : void {
         this._mode = param1;
         this._vd.setScreenMode(param1,param2);
      }
      
      public function setAngle(param1:Number) : void {
         this._vd.setAngle(param1);
      }
      
      public function saveWatchingRecord(param1:Boolean = false) : void {
         if(param1)
         {
            this._playerProxy.fsoProxy.removeUserWatchingRecord(this._playListData.vidEncoded);
            return;
         }
         if(this._playOver)
         {
            return;
         }
         if(this._playListData.totalTime >= 60 * 10)
         {
            if(this._nsTime > 60 * 2 && this._nsTime < this._playListData.totalTime - 60 * 2)
            {
               this._playerProxy.fsoProxy.saveUserWatchingRecord(this._playListData.vidEncoded,this._nsTime);
            }
         }
         this._lastRecordWatchingTime = getTimer();
      }
      
      public function saveDownloadSpeed(param1:Number) : void {
         var _loc2_:* = "default";
         if((this._playListData) && (this._playListData.controller))
         {
            _loc2_ = this._playListData.controller.area_dma_code;
         }
         if(param1 == 0)
         {
            return;
         }
         this._playerProxy.fsoProxy.saveDownloadSpeed(_loc2_,int(param1));
      }
      
      public function get playListData() : IPlayListData {
         return this._playListData;
      }
      
      public function get loadedTime() : Number {
         return this._loadedTime;
      }
      
      public function get currentPlayVideo() : IVideo {
         return null;
      }
      
      public function get currentLoadingNum() : Number {
         return 0;
      }
      
      public function get currentVideoNum() : Number {
         return 0;
      }
      
      public function get isPause() : Boolean {
         return this._isPause;
      }
      
      public function get dfTable() : DropFrameTable {
         return this._dfTable;
      }
      
      public function stopSizeRender(param1:Boolean = true) : void {
         this._isRenderSize = !param1;
         this.setWH(this._width,this._height);
      }
      
      public function get video() : Video {
         return this._vd.video;
      }
      
      public function get currentVideoRealWidth() : Number {
         if(this.currentPlayVideo == null)
         {
            return 320;
         }
         return this.currentPlayVideo.videoRealWidth;
      }
      
      public function get currentVideoRealHeight() : Number {
         if(this.currentPlayVideo == null)
         {
            return 240;
         }
         return this.currentPlayVideo.videoRealHeight;
      }
      
      protected function get currentNetstream() : NetStream {
         if(this.currentPlayVideo == null)
         {
            return null;
         }
         return this.currentPlayVideo.ns;
      }
      
      public function get currentVideoGotMetadata() : Boolean {
         if(this.currentPlayVideo == null)
         {
            return false;
         }
         return this.currentPlayVideo.isGotMetadata;
      }
   }
}
